<template>
  <div>
    <el-skeleton v-if="skeletonLoading" :rows="10" class="mt-20 mb-20" animated/>
    <div v-show="!skeletonLoading" :gutter="20" class="mt-20" v-loading="loading">
      <div class="flex-space-between mt-20">
        <div class="font-bold font-s-18">签到中心</div>
        <div class="color-grey font-s-14">
          <i class="el-icon-warning-outline"></i>
          签到规则
        </div>
      </div>
      <el-divider></el-divider>
      <el-row>
        <el-col :span="18">
          <!--          签到日历-->
          <el-calendar>
            <template
              slot="dateCell"
              slot-scope="{date, data}">
              <div>
                <div v-if="isReport(data.day)!=-3">
                  <span>{{ data.day.slice(8) }}</span>
                  <span v-if="isReport(data.day)==0" class="report-success">✔</span>
                  <p class="font-s-13 color-grey mt-2"
                     v-if=" reportList!=undefined && reportList.findIndex((v)=>(v==data.day))!=-1">
                    <svg t="1680423108793" class="icon icon-size-16 svg-translateY-3" viewBox="0 0 1024 1024"
                         version="1.1"
                         xmlns="http://www.w3.org/2000/svg" p-id="7773">
                      <path
                        d="M517.418444 965.859231c-9.63279 0-19.437594-0.344028-29.070385-0.860071-59.00084-3.612296-115.593482-18.577524-168.2298-43.863598-54.700487-26.318159-103.036452-62.78515-143.631782-108.884932-40.59533-45.927768-70.869814-98.392071-90.135394-156.016798-18.577524-55.560558-26.146145-113.529313-22.533848-172.530153s18.577524-115.593482 43.863598-168.2298c26.318159-54.700487 62.78515-103.036452 108.884932-143.631782 45.927768-40.59533 98.392071-70.869814 156.016798-90.135394 46.271796-15.48127 94.607761-23.393919 143.459768-23.393919 9.63279 0 19.437594 0.344028 29.070385 0.860071 58.828826 3.612296 115.593482 18.577524 168.401814 43.863598 54.700487 26.318159 103.036452 62.78515 143.631782 108.884932 47.991937 54.356459 81.19066 118.345708 99.252142 189.903578l0 0.172014 0 0.172014c3.612296 11.180917 0.344028 23.393919-8.256677 31.134554-5.332437 4.644381-12.213002 7.396607-19.26558 7.396607-8.428691 0-16.341341-3.612296-22.017806-9.976818-1.720141-1.892155-2.752226-3.956325-3.612296-5.676466l-0.172014-0.344028-0.860071-1.032085-0.516042-2.236183c-14.793214-61.409037-44.379641-117.657652-88.071225-166.853687-69.665715-78.610449-165.649588-125.570301-270.062154-131.934823-8.256677-0.516042-16.685369-0.860071-24.942046-0.860071-47.647909 0-94.263733 8.428691-138.299345 25.11406-44.207626 16.685369-84.974971 41.283387-120.92592 72.933983-78.610449 69.321687-125.570301 165.133546-131.934823 269.890139-6.536536 104.584579 28.210314 205.728876 97.532001 284.339325 69.149672 78.610449 165.133546 125.570301 269.890139 132.106837 8.256677 0.516042 16.685369 0.860071 24.942046 0.860071 47.647909 0 94.263733-8.428691 138.299345-25.11406 44.207626-16.685369 84.974971-41.283387 120.92592-72.933983 62.78515-55.560558 105.44465-128.322526 123.506131-211.061314l0.172014-0.344028 0-0.344028c0.688056-6.70855 3.78431-12.901058 8.77272-17.889467 0.172014-0.172014 0.344028-0.344028 0.344028-0.344028 0.172014-0.172014 0.344028-0.344028 0.516042-0.516042 5.332437-4.644381 12.213002-7.224593 19.437594-7.224593 7.568621 0 14.793214 2.752226 20.125651 7.912649 5.504452 5.160423 8.77272 12.55703 8.944734 20.985721 0 0.860071-0.172014 1.720141-0.172014 2.408198-19.953637 98.392071-69.665715 184.743155-143.631782 249.764488-45.755753 40.423316-98.220057 70.697799-156.016798 90.135394C614.606417 957.946582 566.270452 965.859231 517.418444 965.859231zM470.630606 729.339829 470.630606 485.939862l-3.612296 1.032085c-21.501764 6.192508-40.939358 12.213002-59.172854 18.233496-7.912649 2.580212-18.233496 5.332437-29.070385 8.084663-14.965228 3.956325-30.618512 7.912649-40.423316 12.040988l-1.720141 0.688056 0 127.806484-70.525785 0 0-199.536368 70.353771 0 0 29.414413 3.78431-1.376113c5.84848-2.236183 16.513355-4.644381 27.866286-7.224593 11.69696-2.752226 24.942046-5.84848 35.090879-9.116748 19.437594-6.192508 41.455401-12.213002 65.365362-17.373425l2.236183-0.516042 0-51.088191-2.92424 0.172014c-38.531161 2.064169-74.654124 3.268268-106.992777 3.440282-16.685369 0.172014-32.510667 0.860071-46.271796 1.376113-11.69696 0.516042-22.877877 1.032085-32.854695 1.032085l-12.901058-50.572148c17.029397 0.172014 34.402822 1.376113 51.260205 2.408198 17.717453 1.204099 35.950949 2.408198 53.15236 2.408198 5.676466 0 10.836889-0.172014 15.997312-0.344028 38.359147-2.064169 77.062322-5.504452 115.07744-10.492861 38.015118-4.988409 75.858223-11.352931 112.325214-19.26558 35.778935-7.396607 72.761969-16.857383 110.261045-27.694272 6.020494 14.793214 10.836889 26.146145 14.965228 36.466991 0.860071 2.064169 1.720141 4.128339 2.408198 6.020494 1.204099 2.752226 2.236183 5.504452 3.440282 8.084663 1.548127 3.78431 3.096254 7.396607 4.472367 10.492861l0.688056 1.720141c1.032085 2.92424 2.408198 6.020494 3.956325 9.116748-32.682681 5.332437-66.569461 9.804804-100.456241 13.245087-24.942046 2.580212-56.764656 4.816395-84.802956 6.880564-9.804804 0.688056-18.921552 1.376113-27.006215 2.064169l-2.580212 0.172014 0 35.950949 3.096254-0.344028c11.008903-1.032085 25.630102-1.548127 41.283387-1.548127 15.653284 0 30.446498 0.516042 41.627415 1.548127 31.82261 2.752226 57.452713 8.428691 76.202251 17.029397 18.749538 8.428691 33.198723 17.889467 43.003528 27.866286 9.804804 10.148833 16.169326 20.469679 19.26558 30.618512 3.440282 10.836889 5.332437 24.081975 6.020494 30.274483 0.344028 8.77272 0.860071 18.921552 1.204099 30.274483 0.344028 11.008903 0 22.361834-1.204099 33.714766-1.204099 11.352931-3.440282 22.361834-6.70855 32.682681-3.268268 10.492861-7.912649 19.26558-13.761129 26.490173-6.192508 7.224593-13.933143 12.55703-23.909961 16.169326-5.84848 2.064169-12.901058 3.096254-20.469679 3.096254-5.332437 0-11.008903-0.516042-17.029397-1.376113-13.589115-2.064169-25.630102-4.644381-36.122963-7.912649-11.352931-3.440282-20.469679-6.70855-27.694272-9.804804-8.600706-3.612296-15.653284-6.880564-21.32975-9.976818l3.268268-31.650596c13.073072 6.364522 24.942046 10.492861 35.090879 11.868974 2.580212 0.344028 5.160423 0.516042 7.740635 0.516042 2.408198 0 4.988409-0.172014 7.396607-0.688056 4.644381-0.860071 9.116748-2.752226 13.589115-5.676466 4.300353-2.92424 7.912649-7.396607 10.664875-13.417101 2.92424-6.020494 4.644381-13.417101 5.504452-22.18982 2.064169-23.393919 2.580212-41.455401 1.720141-53.324374-0.344028-6.536536-0.860071-8.600706-1.204099-9.63279 0-3.440282-0.344028-7.740635-0.860071-12.901058-0.516042-5.160423-2.064169-9.804804-4.300353-13.761129-4.300353-7.396607-12.385016-14.277171-24.598018-20.813707-9.976818-5.332437-23.909961-7.912649-40.939358-7.912649-3.440282 0-6.880564 0.172014-10.492861 0.344028l-0.172014 0c-7.912649 0.860071-15.997312 1.720141-23.565933 2.408198-2.92424 0.344028-7.568621 0.688056-13.073072 1.032085-9.804804 0.860071-20.985721 1.548127-26.834201 2.752226l-2.236183 0.344028 0 252.860742-70.869814 0L470.630606 729.339829 470.630606 729.339829 470.630606 729.339829z"
                        fill="#ffa502" p-id="7774"></path>
                    </svg>
                    +{{ addAcurrency }}
                  </p>
                  <p v-if="isReport(data.day)==-1" class="font-s-13 color-grey mt-2 line-height-18">待补签</p>
                  <p v-if="isReport(data.day)==-2" class="font-s-13 color-grey mt-2 line-height-18">
                    <svg t="1680423108793" class="icon icon-size-16 svg-translateY-4" viewBox="0 0 1024 1024"
                         version="1.1"
                         xmlns="http://www.w3.org/2000/svg" p-id="7773">
                      <path
                        d="M517.418444 965.859231c-9.63279 0-19.437594-0.344028-29.070385-0.860071-59.00084-3.612296-115.593482-18.577524-168.2298-43.863598-54.700487-26.318159-103.036452-62.78515-143.631782-108.884932-40.59533-45.927768-70.869814-98.392071-90.135394-156.016798-18.577524-55.560558-26.146145-113.529313-22.533848-172.530153s18.577524-115.593482 43.863598-168.2298c26.318159-54.700487 62.78515-103.036452 108.884932-143.631782 45.927768-40.59533 98.392071-70.869814 156.016798-90.135394 46.271796-15.48127 94.607761-23.393919 143.459768-23.393919 9.63279 0 19.437594 0.344028 29.070385 0.860071 58.828826 3.612296 115.593482 18.577524 168.401814 43.863598 54.700487 26.318159 103.036452 62.78515 143.631782 108.884932 47.991937 54.356459 81.19066 118.345708 99.252142 189.903578l0 0.172014 0 0.172014c3.612296 11.180917 0.344028 23.393919-8.256677 31.134554-5.332437 4.644381-12.213002 7.396607-19.26558 7.396607-8.428691 0-16.341341-3.612296-22.017806-9.976818-1.720141-1.892155-2.752226-3.956325-3.612296-5.676466l-0.172014-0.344028-0.860071-1.032085-0.516042-2.236183c-14.793214-61.409037-44.379641-117.657652-88.071225-166.853687-69.665715-78.610449-165.649588-125.570301-270.062154-131.934823-8.256677-0.516042-16.685369-0.860071-24.942046-0.860071-47.647909 0-94.263733 8.428691-138.299345 25.11406-44.207626 16.685369-84.974971 41.283387-120.92592 72.933983-78.610449 69.321687-125.570301 165.133546-131.934823 269.890139-6.536536 104.584579 28.210314 205.728876 97.532001 284.339325 69.149672 78.610449 165.133546 125.570301 269.890139 132.106837 8.256677 0.516042 16.685369 0.860071 24.942046 0.860071 47.647909 0 94.263733-8.428691 138.299345-25.11406 44.207626-16.685369 84.974971-41.283387 120.92592-72.933983 62.78515-55.560558 105.44465-128.322526 123.506131-211.061314l0.172014-0.344028 0-0.344028c0.688056-6.70855 3.78431-12.901058 8.77272-17.889467 0.172014-0.172014 0.344028-0.344028 0.344028-0.344028 0.172014-0.172014 0.344028-0.344028 0.516042-0.516042 5.332437-4.644381 12.213002-7.224593 19.437594-7.224593 7.568621 0 14.793214 2.752226 20.125651 7.912649 5.504452 5.160423 8.77272 12.55703 8.944734 20.985721 0 0.860071-0.172014 1.720141-0.172014 2.408198-19.953637 98.392071-69.665715 184.743155-143.631782 249.764488-45.755753 40.423316-98.220057 70.697799-156.016798 90.135394C614.606417 957.946582 566.270452 965.859231 517.418444 965.859231zM470.630606 729.339829 470.630606 485.939862l-3.612296 1.032085c-21.501764 6.192508-40.939358 12.213002-59.172854 18.233496-7.912649 2.580212-18.233496 5.332437-29.070385 8.084663-14.965228 3.956325-30.618512 7.912649-40.423316 12.040988l-1.720141 0.688056 0 127.806484-70.525785 0 0-199.536368 70.353771 0 0 29.414413 3.78431-1.376113c5.84848-2.236183 16.513355-4.644381 27.866286-7.224593 11.69696-2.752226 24.942046-5.84848 35.090879-9.116748 19.437594-6.192508 41.455401-12.213002 65.365362-17.373425l2.236183-0.516042 0-51.088191-2.92424 0.172014c-38.531161 2.064169-74.654124 3.268268-106.992777 3.440282-16.685369 0.172014-32.510667 0.860071-46.271796 1.376113-11.69696 0.516042-22.877877 1.032085-32.854695 1.032085l-12.901058-50.572148c17.029397 0.172014 34.402822 1.376113 51.260205 2.408198 17.717453 1.204099 35.950949 2.408198 53.15236 2.408198 5.676466 0 10.836889-0.172014 15.997312-0.344028 38.359147-2.064169 77.062322-5.504452 115.07744-10.492861 38.015118-4.988409 75.858223-11.352931 112.325214-19.26558 35.778935-7.396607 72.761969-16.857383 110.261045-27.694272 6.020494 14.793214 10.836889 26.146145 14.965228 36.466991 0.860071 2.064169 1.720141 4.128339 2.408198 6.020494 1.204099 2.752226 2.236183 5.504452 3.440282 8.084663 1.548127 3.78431 3.096254 7.396607 4.472367 10.492861l0.688056 1.720141c1.032085 2.92424 2.408198 6.020494 3.956325 9.116748-32.682681 5.332437-66.569461 9.804804-100.456241 13.245087-24.942046 2.580212-56.764656 4.816395-84.802956 6.880564-9.804804 0.688056-18.921552 1.376113-27.006215 2.064169l-2.580212 0.172014 0 35.950949 3.096254-0.344028c11.008903-1.032085 25.630102-1.548127 41.283387-1.548127 15.653284 0 30.446498 0.516042 41.627415 1.548127 31.82261 2.752226 57.452713 8.428691 76.202251 17.029397 18.749538 8.428691 33.198723 17.889467 43.003528 27.866286 9.804804 10.148833 16.169326 20.469679 19.26558 30.618512 3.440282 10.836889 5.332437 24.081975 6.020494 30.274483 0.344028 8.77272 0.860071 18.921552 1.204099 30.274483 0.344028 11.008903 0 22.361834-1.204099 33.714766-1.204099 11.352931-3.440282 22.361834-6.70855 32.682681-3.268268 10.492861-7.912649 19.26558-13.761129 26.490173-6.192508 7.224593-13.933143 12.55703-23.909961 16.169326-5.84848 2.064169-12.901058 3.096254-20.469679 3.096254-5.332437 0-11.008903-0.516042-17.029397-1.376113-13.589115-2.064169-25.630102-4.644381-36.122963-7.912649-11.352931-3.440282-20.469679-6.70855-27.694272-9.804804-8.600706-3.612296-15.653284-6.880564-21.32975-9.976818l3.268268-31.650596c13.073072 6.364522 24.942046 10.492861 35.090879 11.868974 2.580212 0.344028 5.160423 0.516042 7.740635 0.516042 2.408198 0 4.988409-0.172014 7.396607-0.688056 4.644381-0.860071 9.116748-2.752226 13.589115-5.676466 4.300353-2.92424 7.912649-7.396607 10.664875-13.417101 2.92424-6.020494 4.644381-13.417101 5.504452-22.18982 2.064169-23.393919 2.580212-41.455401 1.720141-53.324374-0.344028-6.536536-0.860071-8.600706-1.204099-9.63279 0-3.440282-0.344028-7.740635-0.860071-12.901058-0.516042-5.160423-2.064169-9.804804-4.300353-13.761129-4.300353-7.396607-12.385016-14.277171-24.598018-20.813707-9.976818-5.332437-23.909961-7.912649-40.939358-7.912649-3.440282 0-6.880564 0.172014-10.492861 0.344028l-0.172014 0c-7.912649 0.860071-15.997312 1.720141-23.565933 2.408198-2.92424 0.344028-7.568621 0.688056-13.073072 1.032085-9.804804 0.860071-20.985721 1.548127-26.834201 2.752226l-2.236183 0.344028 0 252.860742-70.869814 0L470.630606 729.339829 470.630606 729.339829 470.630606 729.339829z"
                        fill="#747d8c" p-id="7774"></path>
                    </svg>
                    +{{ addAcurrency }}
                  </p>
                </div>
                <div v-if="isReport(data.day)==-3" @click="addReports(data.day)">
                  <span class="the-same-day background-color-theme font-s-14">{{ data.day.slice(8) }}</span>
                  <p class="font-s-12 color-theme mt-8">点击签到</p>
                </div>
              </div>
            </template>
          </el-calendar>
        </el-col>
        <el-col :span="6" style="margin-top: 20px;padding: 0 20px">
          <div class="time-ticp background-color-theme-2 color-theme"
               v-if="isReport($utils.parseTime(new Date(),'{y}-{m}-{d}'))==0">今日已签到
          </div>
          <div class="time-ticp-s"
               v-if="isReport($utils.parseTime(new Date(),'{y}-{m}-{d}'))==-3"
               @click="addReports($utils.parseTime(new Date(),'{y}-{m}-{d}'))">
            <svg t="1680423108793" class="icon icon-size-24 svg-translateY-6" viewBox="0 0 1024 1024" version="1.1"
                 xmlns="http://www.w3.org/2000/svg" p-id="7773">
              <path
                d="M517.418444 965.859231c-9.63279 0-19.437594-0.344028-29.070385-0.860071-59.00084-3.612296-115.593482-18.577524-168.2298-43.863598-54.700487-26.318159-103.036452-62.78515-143.631782-108.884932-40.59533-45.927768-70.869814-98.392071-90.135394-156.016798-18.577524-55.560558-26.146145-113.529313-22.533848-172.530153s18.577524-115.593482 43.863598-168.2298c26.318159-54.700487 62.78515-103.036452 108.884932-143.631782 45.927768-40.59533 98.392071-70.869814 156.016798-90.135394 46.271796-15.48127 94.607761-23.393919 143.459768-23.393919 9.63279 0 19.437594 0.344028 29.070385 0.860071 58.828826 3.612296 115.593482 18.577524 168.401814 43.863598 54.700487 26.318159 103.036452 62.78515 143.631782 108.884932 47.991937 54.356459 81.19066 118.345708 99.252142 189.903578l0 0.172014 0 0.172014c3.612296 11.180917 0.344028 23.393919-8.256677 31.134554-5.332437 4.644381-12.213002 7.396607-19.26558 7.396607-8.428691 0-16.341341-3.612296-22.017806-9.976818-1.720141-1.892155-2.752226-3.956325-3.612296-5.676466l-0.172014-0.344028-0.860071-1.032085-0.516042-2.236183c-14.793214-61.409037-44.379641-117.657652-88.071225-166.853687-69.665715-78.610449-165.649588-125.570301-270.062154-131.934823-8.256677-0.516042-16.685369-0.860071-24.942046-0.860071-47.647909 0-94.263733 8.428691-138.299345 25.11406-44.207626 16.685369-84.974971 41.283387-120.92592 72.933983-78.610449 69.321687-125.570301 165.133546-131.934823 269.890139-6.536536 104.584579 28.210314 205.728876 97.532001 284.339325 69.149672 78.610449 165.133546 125.570301 269.890139 132.106837 8.256677 0.516042 16.685369 0.860071 24.942046 0.860071 47.647909 0 94.263733-8.428691 138.299345-25.11406 44.207626-16.685369 84.974971-41.283387 120.92592-72.933983 62.78515-55.560558 105.44465-128.322526 123.506131-211.061314l0.172014-0.344028 0-0.344028c0.688056-6.70855 3.78431-12.901058 8.77272-17.889467 0.172014-0.172014 0.344028-0.344028 0.344028-0.344028 0.172014-0.172014 0.344028-0.344028 0.516042-0.516042 5.332437-4.644381 12.213002-7.224593 19.437594-7.224593 7.568621 0 14.793214 2.752226 20.125651 7.912649 5.504452 5.160423 8.77272 12.55703 8.944734 20.985721 0 0.860071-0.172014 1.720141-0.172014 2.408198-19.953637 98.392071-69.665715 184.743155-143.631782 249.764488-45.755753 40.423316-98.220057 70.697799-156.016798 90.135394C614.606417 957.946582 566.270452 965.859231 517.418444 965.859231zM470.630606 729.339829 470.630606 485.939862l-3.612296 1.032085c-21.501764 6.192508-40.939358 12.213002-59.172854 18.233496-7.912649 2.580212-18.233496 5.332437-29.070385 8.084663-14.965228 3.956325-30.618512 7.912649-40.423316 12.040988l-1.720141 0.688056 0 127.806484-70.525785 0 0-199.536368 70.353771 0 0 29.414413 3.78431-1.376113c5.84848-2.236183 16.513355-4.644381 27.866286-7.224593 11.69696-2.752226 24.942046-5.84848 35.090879-9.116748 19.437594-6.192508 41.455401-12.213002 65.365362-17.373425l2.236183-0.516042 0-51.088191-2.92424 0.172014c-38.531161 2.064169-74.654124 3.268268-106.992777 3.440282-16.685369 0.172014-32.510667 0.860071-46.271796 1.376113-11.69696 0.516042-22.877877 1.032085-32.854695 1.032085l-12.901058-50.572148c17.029397 0.172014 34.402822 1.376113 51.260205 2.408198 17.717453 1.204099 35.950949 2.408198 53.15236 2.408198 5.676466 0 10.836889-0.172014 15.997312-0.344028 38.359147-2.064169 77.062322-5.504452 115.07744-10.492861 38.015118-4.988409 75.858223-11.352931 112.325214-19.26558 35.778935-7.396607 72.761969-16.857383 110.261045-27.694272 6.020494 14.793214 10.836889 26.146145 14.965228 36.466991 0.860071 2.064169 1.720141 4.128339 2.408198 6.020494 1.204099 2.752226 2.236183 5.504452 3.440282 8.084663 1.548127 3.78431 3.096254 7.396607 4.472367 10.492861l0.688056 1.720141c1.032085 2.92424 2.408198 6.020494 3.956325 9.116748-32.682681 5.332437-66.569461 9.804804-100.456241 13.245087-24.942046 2.580212-56.764656 4.816395-84.802956 6.880564-9.804804 0.688056-18.921552 1.376113-27.006215 2.064169l-2.580212 0.172014 0 35.950949 3.096254-0.344028c11.008903-1.032085 25.630102-1.548127 41.283387-1.548127 15.653284 0 30.446498 0.516042 41.627415 1.548127 31.82261 2.752226 57.452713 8.428691 76.202251 17.029397 18.749538 8.428691 33.198723 17.889467 43.003528 27.866286 9.804804 10.148833 16.169326 20.469679 19.26558 30.618512 3.440282 10.836889 5.332437 24.081975 6.020494 30.274483 0.344028 8.77272 0.860071 18.921552 1.204099 30.274483 0.344028 11.008903 0 22.361834-1.204099 33.714766-1.204099 11.352931-3.440282 22.361834-6.70855 32.682681-3.268268 10.492861-7.912649 19.26558-13.761129 26.490173-6.192508 7.224593-13.933143 12.55703-23.909961 16.169326-5.84848 2.064169-12.901058 3.096254-20.469679 3.096254-5.332437 0-11.008903-0.516042-17.029397-1.376113-13.589115-2.064169-25.630102-4.644381-36.122963-7.912649-11.352931-3.440282-20.469679-6.70855-27.694272-9.804804-8.600706-3.612296-15.653284-6.880564-21.32975-9.976818l3.268268-31.650596c13.073072 6.364522 24.942046 10.492861 35.090879 11.868974 2.580212 0.344028 5.160423 0.516042 7.740635 0.516042 2.408198 0 4.988409-0.172014 7.396607-0.688056 4.644381-0.860071 9.116748-2.752226 13.589115-5.676466 4.300353-2.92424 7.912649-7.396607 10.664875-13.417101 2.92424-6.020494 4.644381-13.417101 5.504452-22.18982 2.064169-23.393919 2.580212-41.455401 1.720141-53.324374-0.344028-6.536536-0.860071-8.600706-1.204099-9.63279 0-3.440282-0.344028-7.740635-0.860071-12.901058-0.516042-5.160423-2.064169-9.804804-4.300353-13.761129-4.300353-7.396607-12.385016-14.277171-24.598018-20.813707-9.976818-5.332437-23.909961-7.912649-40.939358-7.912649-3.440282 0-6.880564 0.172014-10.492861 0.344028l-0.172014 0c-7.912649 0.860071-15.997312 1.720141-23.565933 2.408198-2.92424 0.344028-7.568621 0.688056-13.073072 1.032085-9.804804 0.860071-20.985721 1.548127-26.834201 2.752226l-2.236183 0.344028 0 252.860742-70.869814 0L470.630606 729.339829 470.630606 729.339829 470.630606 729.339829z"
                fill="#fff200" p-id="7774"></path>
            </svg>
            点击签到
          </div>
          <div class="data-re-br">
            <span class="color-theme">{{ ctnFatalism }}</span>
            <p>连续签到</p>
          </div>
          <div class="data-re-br">
            <span>{{ sumFatalism }}</span>
            <p>累计签到</p>
          </div>
          <div class="data-re-br">
            <span>{{ acurrency }}</span>
            <p>A 币数量
              <el-tooltip effect="light" placement="bottom-end">
                    <span slot="content">
                        A币 主要通过签到和充值获得！<br/>可用于网站内部交易
                    </span>
                <i class="el-icon-warning-outline ml-2 cursor-pointer"></i>
              </el-tooltip>
            </p>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</template>

<script>
// import logoImg from '@/assets/logo/logo.jpg'
// import {addReport, reportList} from "@/api/frontDesk/userReport";

export default {
  name: "daily",
  data() {
    return {
      skeletonLoading: true,
      loading: false,
      logo: "",
      ctnFatalism: 0,
      sumFatalism: 0,
      acurrency: 0,
      userInfo: {
        nickname: null,
        occupation: null,
        avatar: null,
        createTime: null,
        acurrency: null
      },
      addAcurrency: 20,
      reportList: [],
    }
  },
  methods: {
    addReports(data) {
      this.loading = true;
      this.$API("/frontDesk/user/report", "post", null, {
          acurrency: this.addAcurrency,
          reportTime: data,
        }
      ).then(res => {
        if (res.code == 200) {
          this.$modal.msgSuccess("签到成功！");
          this.reportLists();
        }
      })
    },
    reportLists() {
      this.$API("/frontDesk/user/report/list", "get").then(res => {
        this.reportList = res.data.list;
        this.ctnFatalism = res.data.ctnFatalism;
        this.sumFatalism = res.data.sumFatalism;
        this.acurrency = res.data.acurrency;
      }).finally(() => {
        this.loading = false
        this.skeletonLoading = false
      })
    },
    getBasicsUsers() {
      this.$API("/front-desk/user/basics", "get").then(res => {
        if (res != null) {
          this.userInfo = res.data;
        }
      }).finally(() => this.skeletonLoading = false);
    },
    /**
     * -4 用户注册之前
     * -3 当天
     * -2 当前时间以后
     * 0 已签到
     * -1 未签到
     * @param data
     * @returns {number}
     */
    isReport(data) {
      if (data < this.$utils.parseTime(this.userInfo.createTime, "{y}-{m}-{d}")) {
        return -4;
      }
      if (this.reportList != undefined && this.reportList.findIndex((v) => (v == data)) != -1) {
        return 0;
      } else {
        let parseTimes = this.$utils.parseTime(new Date(), "{y}-{m}-{d}");
        if (data == parseTimes) {
          return -3
        }
        if (Date.parse(data) > Date.parse(parseTimes)) return -2;
        return -1;
      }
    },
  },
  mounted() {
    this.getBasicsUsers();
    this.reportLists();
  }
}
</script>

<style>
.menu-fu-div li {
  height: 60px;
  width: 200px;
}

.selected-menu {
  background-color: #FEC171;
}

.data-re-br {
  width: 100%;
  background: #f7f8fa;
  margin-bottom: 20px;
  border-radius: 4px;
  text-align: center;
  padding: 20px 0;
}

.data-re-br span {
  font-size: 32px;
  letter-spacing: 2px;
  font-weight: bold;
}

.data-re-br p {
  font-size: 13px;
  line-height: 20px;
  color: #86909c;
}

.time-ticp {
  height: 60px;
  width: 100%;
  letter-spacing: 1px;
  text-align: center;
  line-height: 60px;
  border-radius: 4px;
  margin-bottom: 20px;
}

.time-ticp-s {
  height: 60px;
  width: 100%;
  color: #FFFFFF;
  background-color: rgba(var(--theme-color-rgb), 0.7);
  cursor: pointer;
  letter-spacing: 1px;
  text-align: center;
  line-height: 60px;
  border-radius: 4px;
  margin-bottom: 20px;
}

.time-ticp-s:hover {
  border: 1px solid var(--theme-color);
}

.report-success {
  margin-left: 6px;
  position: absolute;
}

.the-same-day {
  color: #FFFFFF;
  padding: 4px;
  border-radius: 50%;
}

.el-calendar-table .el-calendar-day {
  height: 70px !important;
  padding: 16px 0 0 0;
  font-size: 18px;
  text-align: center;
}
</style>
